home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Just Call Me Internet
/
Just Call Me Internet.iso
/
com
/
computer
/
casio_st
/
prog_fx
/
oisac2
/
editeur1.txt
< prev
next >
Wrap
Text File
|
1994-03-01
|
2KB
|
35 lines
1 ' *** OISAC 2 *** EDITEUR-MEM1 ***
10 CLS:P=0:PRINTCHR$(9)"*** OISAC 2 *** EDITEUR-MEM *** ADRESSE : PAGE :";:LOCATE10,1:INPUT@7;A:LOCATE0,0:LOCATE25,1:INPUT@3;P:DEFSEG=P*4096:Z=0:CLS
20 H$="":A$="":FORI=0TO14:D=PEEK(A+I):H$=H$+RIGHT$(HEX$(D),2):IFD<32THEND=46
30 A$=A$+CHR$(D):NEXT
50 CLS:IFZ THEN110
100 PRINT" "H$" &H"HEX$(A)" &H"RIGHT$(HEX$(P),2)" ["A$"]";:GOTO120
110 PRINT" "H$" &H"MID$(H$,3,2)LEFT$(H$,2)" &H"MID$(H$,5,2)" &H"MID$(H$,9,2)MID$(H$,7,2)" ["MID$(A$,8,8)"]";
120 $=INPUT$(1,@):CLS
130 IF$="1"OR$="0"THENZ=VAL($):GOTO50
135 IF$="*"THEN10
140 IF$="+"THENA=A+15:GOTO20
145 IF$="-"THENA=A-15:GOTO20
150 IF$="/"THENINPUT"DECALAGE : ",Y:A=A+Y:GOTO20
155 IF$<>"H"THEN160ELSEPRINT"Hexa -> Deci : ";:INPUT@6;Y:IFY<0THENY=65536+Y
156 PRINTY"d":GOTO50
160 IF$="D"THENPRINT"Deci -> Hexa : ";:INPUT@6;Y:PRINT"&H"HEX$(Y):GOTO50
162 IF$="M"THEN1010
164 IF$="R"THEN1030
166 IF$="C"THEN1050
168 IF$="V"THEN1100
170 BEEP:GOTO50
1010 CLS:D=A:PRINT"MODIFIER RAM O/N ? ";:$=INPUT$(1,@):IF$<>"O"THEN50ELSEPRINTTAB(0);:INPUT"ADR DEPART : ",D,"[A]scii/[H]exa ? ",M$,"CHAINE => ",R$
1017 IFM$="A"THEN$=R$:GOTO1020ELSEIFM$<>"H"THEN50ELSEGOSUB1080
1020 DEFSEG=0:S$=HEX$(D):FORI=1TOLEN($):S$=S$+CHR$(PEEKD):POKED,ASC(MID$($,I,1)):D=D+1:NEXTI:A=D-LEN($):GOTO20
1030 CLS:PRINT"RESTORER MODIF O/
N ? ";:$=INPUT$(1,@):CLS:IF$<>"O"THEN50ELSE$=MID$(S$,5,LEN(S$)):D=VAL("&H"+LEFT$(S$,4)):GOTO1020
1050 CLS:INPUT"RECHERCHE O/N ";$:IF$<>"O"THEN50ELSEINPUT"ADR DEPART :",D,"ADR FIN :",F,"PAGE :",P,"[A]scii/[H]exa ? ",$,"CHAINE => ",R$:CLS:IF$="A"THEN$=R$:GOTO1060ELSEIF$<>"H"THEN50ELSEGOSUB1080
1060 DEFSEG=P*4096:P$=LEFT$($,1):I=-1:L=LEN($)
1065 I=I+1:IFD+I>FTHENBEEP:GOTO50ELSEIFP$<>CHR$(PEEK(D+I))THEN1065ELSEQ=1:C=1
1067 Q=Q+1:IFMID$($,Q,1)<>CHR$(PEEK(D+I+Q-1))THEN1065ELSEC=C+1:IFC=L THENA=D+I:Z=0:GOTO20ELSE1067
1080 $="":FORI=1TOLEN(R$)STEP2:$=$+CHR$(VAL("&H"+MID$(R$,I,2))):NEXT:RETURN
1100 INPUT"DEPLACEMENT O/N ";$:IF$<>"O"THEN20ELSEINPUT"ADR DEBUT : ",d,"ADR FIN : ",F,"DESTINATION : ",a:DEFSEG=0
1110 n=F-d:f=d-1:e=n+f:IFFRE1+e-f>=0THENo=a+n-1:X=1771:A=PEEKX:B=PEEK1772:POKEX,204:POKEX+1,247:POKEX+2,5:GOSUB2090:POKEX,A:POKEX+1,B:POKEX+2,0ELSEBEEP:PRINT"IMPOSSIBLE"
1120 PRINT"DEPLACEMENT OK":GOTO50